<?php

use Illuminate\Http\Request;

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/

Route::group(['middleware' => ['cors']], function() {

    Route::middleware('auth.api')->group(function () {

        Route::post('coupon/receive-coupon', 'CouponController@receiveCoupon');     // 领取优惠券
        Route::get('coupon/user-coupon-list', 'CouponController@getUserCouponList');     // 用户优惠券列表
        Route::get('coupon/coupon-list', 'CouponController@getCouponList');     // 获取优惠券列表

    });
});